<?php
	if(!defined('__HIGHSCOREARRAYLIST_PHP__'))
	{
		define('__HIGHSCOREARRAYLIST_PHP__', true);
		
		include("ArrayList.php");
		include("Highscore.php");
		include("IComparable.php");
		
		/**
		 * @class An array list for specific use with the Highscore class.
		 * Overrides the sortArrayList() method, using the IComparable interface
		 */
		class HighscoreArrayList extends ArrayList
		{
			/**
			 * @override Sorts the elements of the array according to their implementation
			 * of the IComparable interface
			 * 
			 * @see ArrayList#sortArrayList
			 * @see IComparable#compareTo
			 * @see compareIComparable (from IComparable.php)
			 */
			function sortArrayList()
			{
				usort($this->m_Array, "compareIComparables");
			}
		}
	}
?>
